package com.gitee.wsl.result.tran

import com.gitee.wsl.flow.transform.filter
import com.gitee.wsl.result.EntryResult
import kotlinx.coroutines.flow.Flow
import kotlinx.coroutines.flow.map

fun <T,R> Flow<EntryResult<T, R>>.filterSuccess() = filter { it.isOk }.map { it.value }